package com.hl.service;

import com.hl.mapper.CompanyMapper;
import com.hl.pojo.Company;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class CompanyServiceImpl implements CompanyService {
    @Autowired
    private CompanyMapper companyMapper;

    @Override
    public Integer add(Company company) {
        return companyMapper.add(company);
    }

    @Override
    public Integer update(Company company) {
        return companyMapper.update(company);
    }

    @Override
    public Integer delete(Integer id) {
        return companyMapper.delete(id);
    }

    @Override
    public Company findById(Integer id) {
        return companyMapper.findById(id);
    }

    @Override
    public List<Company> findAll() {
        return companyMapper.findAll();
    }
    @Override
    public List<Company> findAll1() {
        return companyMapper.findAll1();
    }
    @Override
    public List<Company> findAll2(String name) {
        return companyMapper.findAll2(name);
    }
}
